$.ajax({
	type: "get",
	url: "../json/indexDiv.json",
	dataType: "json",
	success: function(data){
		console.log(data)

		doChangeBooks(data[0],null,$("#books"),null);
		doChangeBooks(null,data[2],null,$("#topBoxCenterBookDiv"));

		function doChangeBooks(obj,sbj,id,sd){
			for(var i in sbj){
				for(var s = 0; s <= 3; s++){
					var thisBooks = "<div><a href='list.html'><img src='" + sbj[i][s].img + "' /></a></div>"; 
					sd.append(thisBooks);
				}
			}

			for(var i in obj){
				for(var j in obj[i]){
					var 
					thisBooks = "<div class='ajaxC'><div class='ajaxT'><img src='" + obj[i][j].img + "' /></div><div class='ajaxB'><a href='" + obj[i][j].url + "'>" + obj[i][j].name + "</a></div></div>"; 
					id.append(thisBooks);
				}
			}
		}	
	}
});